import request from "@/utils/request"
export type loginInput = {
    account: string
    password: string
}
export type loginResponse = {
    gender:number
    id:number
    tag:string
    username:string
    img:string
}
export const login = (data:loginInput) => {
    return request<loginResponse>({
        url: "/api/user/login",
        method:"post",
        data
    })
}
export type registerInput={
    account:string
    password:string
    secpassword?:string
}
export const register =(data:registerInput)=>{
    return request({
        url:"/api/user/register",
        method:"post",
        data
    })
}
